home *** CD-ROM | disk | FTP | other *** search
/ CU Amiga Super CD-ROM 23 / CU Amiga - Super CD-ROM 23 (June 1998).iso / CreatingGames / Utilities / C / Mesa / widgets-mesa / include / GL / MesaDrawingAreaP.h < prev    next >
Encoding:
C/C++ Source or Header  |  1997-01-31  |  3.8 KB  |  131 lines

  1. /* MesaDrawingAreaP.h -- Private header file for the Mesa widget
  2.    Copyright (C) 1995, 1996 Thorsten.Ohl @ Physik.TH-Darmstadt.de
  3.  
  4.    This library is free software; you can redistribute it and/or
  5.    modify it under the terms of the GNU Library General Public
  6.    License as published by the Free Software Foundation; either
  7.    version 2 of the License, or (at your option) any later version.
  8.  
  9.    This library is distributed in the hope that it will be useful,
  10.    but WITHOUT ANY WARRANTY; without even the implied warranty of
  11.    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  12.    GNU Library General Public License for more details.
  13.  
  14.    You should have received a copy of the GNU Library General Public
  15.    License along with this library; if not, write to the Free Software
  16.    Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  17.  
  18.    $Id: MesaDrawingAreaP.h,v 1.10 1996/09/30 00:21:06 ohl Exp $
  19.  */
  20.  
  21. #ifndef _MesaDrawingAreaP_h
  22. #define _MesaDrawingAreaP_h
  23.  
  24. #include <GL/GLwDrawAP.h>
  25. #include <GL/MesaDrawingArea.h>
  26.  
  27. typedef struct
  28.   {
  29.     char *RCS_Id;
  30.     Widget lists_root;
  31.   }
  32. MesaDrawingAreaClassPart;
  33.  
  34. #ifdef __GLX_MOTIF
  35. typedef struct _MesaMDrawingAreaClassRec
  36.   {
  37.     CoreClassPart core_class;
  38.     XmPrimitiveClassPart primitive_class;
  39.     GLwDrawingAreaClassPart glwDrawingArea_class;
  40.     MesaDrawingAreaClassPart mesaDrawingArea_class;
  41.   }
  42. MesaMDrawingAreaClassRec;
  43. extern MesaMDrawingAreaClassRec mesaMDrawingAreaClassRec;
  44. #else
  45. typedef struct _MesaDrawingAreaClassRec
  46.   {
  47.     CoreClassPart core_class;
  48.     GLwDrawingAreaClassPart glwDrawingArea_class;
  49.     MesaDrawingAreaClassPart mesaDrawingArea_class;
  50.   }
  51. MesaDrawingAreaClassRec;
  52. extern MesaDrawingAreaClassRec mesaDrawingAreaClassRec;
  53. #endif
  54.  
  55. typedef struct
  56.   {
  57.     Boolean ximage;
  58.     XMesaVisual visual;
  59.     XMesaContext context;
  60.     XMesaBuffer buffer;
  61.     Boolean share_lists;
  62.     Widget share_lists_with;
  63.   }
  64. MesaDrawingAreaPart;
  65.  
  66. #ifdef __GLX_MOTIF
  67. typedef struct _MesaMDrawingAreaRec
  68.   {
  69.     CorePart core;
  70.     XmPrimitivePart primitive;
  71.     GLwDrawingAreaPart glwDrawingArea;
  72.     MesaDrawingAreaPart mesaDrawingArea;
  73.   }
  74. MesaMDrawingAreaRec;
  75. #else
  76. typedef struct _MesaDrawingAreaRec
  77.   {
  78.     CorePart core;
  79.     GLwDrawingAreaPart glwDrawingArea;
  80.     MesaDrawingAreaPart mesaDrawingArea;
  81.   }
  82. MesaDrawingAreaRec;
  83. #endif
  84.  
  85. #ifdef __GLX_MOTIF
  86. #define __DRAWINGAREAWIDGET MesaMDrawingAreaWidget
  87. #define __DRAWINGAREACLASS  
  88. #else
  89. #define __DRAWINGAREAWIDGET MesaDrawingAreaWidget
  90. #define __DRAWINGAREACLASS  
  91. #endif
  92.  
  93.  
  94. #define MesaRGBA(_widget) \
  95.    (((__DRAWINGAREAWIDGET)_widget)->glwDrawingArea.rgba)
  96. #define MesaDoublebuffer(_widget) \
  97.    (((__DRAWINGAREAWIDGET)_widget)->glwDrawingArea.doublebuffer)
  98. #define MesaVisual(_widget) \
  99.    (((__DRAWINGAREAWIDGET)_widget)->mesaDrawingArea.visual)
  100. #define MesaContext(_widget) \
  101.    (((__DRAWINGAREAWIDGET)_widget)->mesaDrawingArea.context)
  102. #define MesaBuffer(_widget) \
  103.    (((__DRAWINGAREAWIDGET)_widget)->mesaDrawingArea.buffer)
  104. #define MesaXImage(_widget) \
  105.    (((__DRAWINGAREAWIDGET)_widget)->mesaDrawingArea.ximage)
  106. #define MesaShareLists(_widget) \
  107.    (((__DRAWINGAREAWIDGET)_widget)->mesaDrawingArea.share_lists)
  108. #define MesaShareListsWith(_widget) \
  109.    (((__DRAWINGAREAWIDGET)_widget)->mesaDrawingArea.share_lists_with)
  110.  
  111. #define MesaAlphaSize(_widget) \
  112.    (((__DRAWINGAREAWIDGET)_widget)->glwDrawingArea.alphaSize)
  113. #define MesaDepthSize(_widget) \
  114.    (((__DRAWINGAREAWIDGET)_widget)->glwDrawingArea.depthSize)
  115. #define MesaStencilSize(_widget) \
  116.    (((__DRAWINGAREAWIDGET)_widget)->glwDrawingArea.stencilSize)
  117. #define MesaAccumRedSize(_widget) \
  118.    (((__DRAWINGAREAWIDGET)_widget)->glwDrawingArea.accumRedSize)
  119.  
  120. #ifdef __GLX_MOTIF
  121. #define MesaListsRoot \
  122.    (mesaMDrawingAreaClassRec.mesaDrawingArea_class.lists_root)
  123. #else
  124. #define MesaListsRoot \
  125.    (mesaDrawingAreaClassRec.mesaDrawingArea_class.lists_root)
  126. #endif
  127.  
  128. #define AVOID_MESABUFFER_INTERFACE 1
  129.  
  130. #endif /* _MesaDrawingAreaP_h */
  131.